const express = require('express'); //引入express模块
const userRouter = require('./user'); //引入user模块
const regRouter = require('./reg'); //引入reg模块
const loginRouter = require('./login'); //引入login模块
const tian_jiaRouter = require('./tian_jia'); //引入tian_jia模块
const guan_liRouter = require('./guan_li'); //引入guan_li模块

//路由中间件
const router = express.Router();
module.exports = router;

router.use(
    express.urlencoded({extended:false}),
    express.json()
)

//路由
router.use('/user', userRouter)
router.use('/reg', regRouter)
router.use('/login', loginRouter)
router.use('/tian_jia', tian_jiaRouter)
router.use('/guan_li', guan_liRouter)